home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 6523 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  857 b 

  1. Path: inforamp.net!usenet
  2. From: dsheuman@inforamp.net (Danny Heuman)
  3. Newsgroups: comp.lang.c
  4. Subject: String Arrays and string parsing
  5. Date: Mon, 19 Feb 1996 12:58:24 GMT
  6. Organization: InfoRamp Inc., Toronto, Ontario (416) 363-9100
  7. Message-ID: <31287278.789445@news.inforamp.net>
  8. Reply-To: dsheuman@inforamp.net
  9. NNTP-Posting-Host: ts10-03.tor.inforamp.net
  10. X-Newsreader: Forte Agent .99d/32.182
  11.  
  12. I have day, month, and year as DDMMMYYYY and would like to parse it
  13. out in to DD, MMM, YYYY.  I can parse the DD out by using
  14. strncpy(into1, from1, 2).  I can parse the YYYY out by doing
  15. strcpy(into3, from1 + 5).  How can I parse out the MMM?  Can I use
  16. either of these functions that work above, strncpy or strcpy?  If so,
  17. once parsed, do I have to attach an '\0' to the end of it to keep it
  18. as a character string?
  19.  
  20. Thanks,
  21.  
  22.  
  23. Danny Heuman
  24. dsheuman@inforamp.net
  25.